<?php
// +---------------------------------------------------------------------+
// | OneBase    | [ WE CAN DO IT JUST THINK ]                            |
// +---------------------------------------------------------------------+
// | Licensed   | http://www.apache.org/licenses/LICENSE-2.0 )           |
// +---------------------------------------------------------------------+
// | Author     | Bigotry <3162875@qq.com>                               |
// +---------------------------------------------------------------------+
// | Repository | https://gitee.com/Bigotry/OneBase                      |
// +---------------------------------------------------------------------+

namespace app\api\controller;



/**
 * Gap控制器
 */
class Gap extends ApiBase
{



    /**
     * 币币账户列表接口
     */
    public function currency_account(){
        return $this->apiReturn($this->logicGap->currency_account($this->param));
    }


    /**
     * 法币账户列表接口
     */
    public function french_currency_account(){
        return $this->apiReturn($this->logicGap->french_currency_account($this->param));
    }
    /**
     * 充币地址接口
     */
    public function get_address(){
        return $this->apiReturn($this->logicGap->get_address($this->param));
    }

    /**
     * 币币账户财务记录接口
     */
    public function currency_account_log(){
        return $this->apiReturn($this->logicGap->currency_account_log($this->param));
    }


    /**
     * 法币账户财务记录接口
     */
    public function french_currency_account_log(){
        return $this->apiReturn($this->logicGap->french_currency_account_log($this->param));
    }
    /**
     * 余额明细记录接口
     */
    public function account_log(){
        return $this->apiReturn($this->logicGap->account_log($this->param));
    }

    /**
     * 法币账户财务类型接口
     */
    public function french_currency_account_type(){
        $arr=[
            [
                'id'=>1,
                'name'=>lang('转入'),
            ],
            [
                'id'=>2,
                'name'=>lang('转出'),
            ],
            [
                'id'=>3,
                'name'=>lang('买入'),
            ],
            [
                'id'=>4,
                'name'=>lang('卖出'),
            ],
        ];
        return $this->apiReturn($arr);
    }


    /**
     * 币币账户到法币账户接口
     */
    public function currency_to_french_currency(){
        return $this->apiReturn($this->logicGap->currency_to_french_currency($this->param));
    }

    /**
     * 法币账户到币币账户接口
     */
    public function french_currency_to_currency(){

        return $this->apiReturn($this->logicGap->french_currency_to_currency($this->param));

    }


    /***
     * 总包提现接口
     */
    public function  wallet_withdrawal (){
        return $this->apiReturn($this->logicGap->wallet_withdrawal($this->param));
    }


    /***
     * 提币接口
     */
    public function  withdrawal (){
        return $this->apiReturn($this->logicGap->withdrawal($this->param));
    }


    /**
     * 币币兑换
     */
    public function exchange(){

        return $this->apiReturn($this->logicGap->exchange($this->param));

    }

    /**
     * 法币转入总包
     */
    public function exchange_money(){

        return $this->apiReturn($this->logicGap->exchange_money($this->param));

    }
    /**
     * 总包入法币
     */
    public function money_exchange_cyn(){

        return $this->apiReturn($this->logicGap->money_exchange_cyn($this->param));

    }

    /**
     * 数字货币钱包充值总包
     */
    public function wallet_recharge(){

        return $this->apiReturn($this->logicGap->wallet_recharge($this->param));

    }



    /**
     * 获取可用钱包首页详情
     */
    public function vailable_account_index(){

        return $this->apiReturn($this->logicGap->vailable_account_index($this->param));

    }

    /**
     * 记录用户地址
     */
    public function user_address(){

        return $this->apiReturn($this->logicGap->user_address($this->param));

    }
    /***
     * 充币记录
     */
    public function recharge_log(){
        return $this->apiReturn($this->logicGap->recharge_log($this->param));
    }

    /***
     * 提币记录
     */
    public function withwral_log(){
        return $this->apiReturn($this->logicGap->withwral_log($this->param));
    }



}
